package com.chlitina.store.modules.cash.dao;

import java.util.List;

import org.springframework.data.jpa.repository.Modifying;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.CrudRepository;
import org.springframework.stereotype.Component;

import com.chlitina.store.common.persistence.BaseDao;
import com.chlitina.store.common.persistence.BaseDaoImpl;
import com.chlitina.store.modules.cash.entity.StoreConsume;

/**
 * StoreConsumeDAO接口
 * @author Songsong.Xu
 * @version 2013-11-07
 */
public interface StoreConsumeDao extends StoreConsumeDaoCustom, CrudRepository<StoreConsume, Long> {
	@Modifying
	@Query("from StoreConsume where STORE_ID=?1")
	public List<StoreConsume> findListByStore(int storeID);

}

/**
 * DAO自定义接口
 * @author Songsong.Xu
 */
interface StoreConsumeDaoCustom extends BaseDao<StoreConsume> {

}

/**
 * DAO自定义接口实现
 * @author Songsong.Xu
 */
@Component
class StoreConsumeDaoImpl extends BaseDaoImpl<StoreConsume> implements StoreConsumeDaoCustom {

}
